package com.health.work.other;

import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;

import com.health.work.R;
import com.health.work.activity.FeedBackActivity;
import com.health.work.utils.DefaultJSONData;
import com.health.work.utils.RequestParamtersUtil;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.TextView;

public class TopViewEvent {
	
	public static void viewShare(Context context){//分享

		Intent intent=new Intent(Intent.ACTION_SEND);   
		intent.setType("text/plain");   
		intent.putExtra(Intent.EXTRA_SUBJECT,"健康护照");   
		intent.putExtra(Intent.EXTRA_TEXT, "照一照，下载您自己的健康护照：www.yihuquan.com");    
		intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);   
		context.startActivity(Intent.createChooser(intent, "分享"));
		new RequestParamtersUtil().AddIntegral(context,"1",new DefaultJSONData() {
			
			@Override
			public void parse(String result) throws JSONException {
				Log.e("AddIntegral", result);
			}
			
			@Override
			public void parse(JSONObject object) throws JSONException {
				
			}
			
			@Override
			public void parse(JSONArray array) throws JSONException {
				
			}
		});
	}
	public static void viewSuggest(Context context){
		Intent intent=new Intent(context,FeedBackActivity.class); 
		context.startActivity(intent);
	}
}
